package tech.aistar.corejava.day08.factory;

/**
 * Created by 豆梦寒 on 2019/7/24.
 */
public class TestFactory {
    public static void main(String[] args){
        //IUserDao userDao = new UserDaoImpl();

        //消费者只需要获取对象即可.
        //将创建bean的事情交给工厂[生产者]
        //将对象的消费者和生产者"解耦合"了 - "各司其职".
        IUseDao1 userDao = MyBeanFactory.getInstance();
        System.out.println(userDao);
    }
}
